//
//  ViewController.swift
//  C072801_UIActivityIndicatorView
//
//  Created by yao_yu on 15/7/28.
//  Copyright © 2015年 yao_yu. All rights reserved.
//

import UIKit

class ViewController: UIViewController {
    
    var _progressIndicatorView = UIActivityIndicatorView(activityIndicatorStyle: UIActivityIndicatorViewStyle.WhiteLarge)
    var progressIndicatorView :UIActivityIndicatorView {
        return _progressIndicatorView
    }

    override func viewDidLoad() {
        super.viewDidLoad()
        // Do any additional setup after loading the view, typically from a nib.

//        _progressIndicatorView.frame = CGRectMake(0, 0, 80, 80)
        _progressIndicatorView.hidesWhenStopped = true
        _progressIndicatorView.color = UIColor.blackColor()
        view.addSubview(_progressIndicatorView)
        progressIndicatorView.startAnimating()
    }

    override func viewDidLayoutSubviews() {
        progressIndicatorView.center = view.center
    }
    
    override func didReceiveMemoryWarning() {
        super.didReceiveMemoryWarning()
        // Dispose of any resources that can be recreated.
    }


}

